package com.jmitxy.service;


import com.jmitxy.dao.CustomerMapper;
import com.jmitxy.entity.Customer;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

@Service
public class CustServiceImp implements CustService {
    @Resource
    private CustomerMapper customerMapper;
 /*   @Override
    public int save(Customer customer) {

        return customerMapper.insert(customer);
    }*/

    @Override
    public Customer findById(String cid) {
            Customer customer=customerMapper.selectByPrimaryKey(cid);
            System.out.println(customer);
            return customer;

    }
    public int insert( Customer customer)
    {
        return customerMapper.insert(customer);
    }
}
